﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Genetatefrompage.aspx.cs"
    Inherits="Genetatefrompage" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <script src="Scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        选择模板
        <asp:DropDownList ID="ddltmp" runat="server">
        </asp:DropDownList>
        <asp:HiddenField ID="hftemp" runat="server" />
        <asp:DropDownList ID="ddltmpv" Visible="false" runat="server">
        </asp:DropDownList>
        店<asp:DropDownList ID="ddlStore" runat="server">
        </asp:DropDownList>
        <asp:DropDownList ID="ddllogo" runat="server" Visible="false">
        </asp:DropDownList>
        <asp:DropDownList ID="ddltype" runat="server">
        </asp:DropDownList>
        <br />
        <asp:FileUpload ID="fumain" runat="server" />
        <asp:Button ID="btngen" runat="server" Text="genetate" OnClick="btngen_Click" />
        <input id="Button2" type="button" value="view" onclick="PopUp();" /><br />
        <br />
        <asp:Button ID="btnsave" runat="server" Text="Save" OnClick="btnsave_Click" />
        <asp:TextBox ID="txtSource" runat="server" Height="277px" TextMode="MultiLine" Width="980px"></asp:TextBox>
        <script type="text/javascript">
            var txtsource = "<%=txtSource.ClientID %>";
            var type = "<%=ddltype.ClientID %>";
            $(function () { $("#" + type).hide(); });
            function PopUp() {
                content = $("#" + txtsource).val();
                var DCIP = window.open("", "newsWindow", "toolbar=no,menubar=no,titlebar=no,directories=no,scrollbars=yes, status=no,fullscreen=no,top=0,left=0,width=1000,height=800");
                DCIP.document.close();
                DCIP.document.write(content.replace(/###/g, "\""));
                DCIP.focus();
            }
 
        </script>
        <asp:HiddenField ID="hfsource" runat="server" />
        <asp:HiddenField ID="hftmp" runat="server" />
    </div>
    </form>
</body>
</html>
